<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="仓鼠的个人官网，记录程序猿的学习历程和作品，包括部落仓鼠工具、仓鼠的博客等项目">
    <meta name="keywords" content="仓鼠,程序猿,部落冲突机器人,阵型库,个人博客,API服务">
    <title>仓鼠の官网 | 程序猿的学习历程与作品集</title>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <link href="https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap" rel="stylesheet">
    <style>
        /* CSS 样式将在下方详细展示 */
        :root {
    --primary-color: #6e48aa;
    --secondary-color: #9d50bb;
    --accent-color: #4776E6;
    --text-color: #333;
    --light-text: #666;
    --lighter-text: #999;
    --bg-color: #f9f9ff;
    --card-bg: #ffffff;
    --gradient: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    --gradient-accent: linear-gradient(135deg, var(--accent-color), #7b4397);
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 15px 35px rgba(0, 0, 0, 0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    overflow-x: hidden;
    line-height: 1.6;
}

/* 加载动画 */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s, visibility 0.5s;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.hamster-wheel {
    width: 100px;
    height: 100px;
    border: 8px solid rgba(255, 255, 255, 0.2);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    position: relative;
}

.hamster {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
    animation: hamster-run 2s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes hamster-run {
    0%, 100% { transform: translate(-50%, -50%) rotate(0deg); }
    25% { transform: translate(-50%, -50%) rotate(90deg); }
    50% { transform: translate(-50%, -50%) rotate(180deg); }
    75% { transform: translate(-50%, -50%) rotate(270deg); }
}

/* 背景元素 */
.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 0, 0, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 0, 0, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: -1;
    opacity: 0.5;
}

.bg-circles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.2;
}

.circle-1 {
    width: 600px;
    height: 600px;
    background: var(--primary-color);
    top: -200px;
    right: -200px;
    animation: float 15s infinite ease-in-out;
}

.circle-2 {
    width: 400px;
    height: 400px;
    background: var(--secondary-color);
    bottom: -100px;
    left: -100px;
    animation: float 12s infinite ease-in-out reverse;
}

.circle-3 {
    width: 300px;
    height: 300px;
    background: var(--accent-color);
    top: 50%;
    left: 30%;
    animation: float 10s infinite ease-in-out;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(50px, 50px); }
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    position: relative;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
}

.logo-icon {
    margin-right: 10px;
    font-size: 28px;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient);
    transition: width 0.3s;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a.active {
    color: var(--primary-color);
}

.nav-links a.active::after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    font-size: 24px;
    cursor: pointer;
}

/* 英雄区域 */
.hero {
    display: flex;
    align-items: center;
    min-height: calc(100vh - 80px);
    padding: 80px 0;
}

.hero-content {
    flex: 1;
    padding-right: 40px;
}

.hero-image {
    flex: 1;
    position: relative;
    height: 500px;
}

.hero-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.3;
}

.title-line {
    display: block;
}

.highlight {
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    position: relative;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--light-text);
    margin-bottom: 30px;
    max-width: 80%;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(110, 72, 170, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(110, 72, 170, 0.4);
}

.btn-secondary {
    background: white;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.btn-secondary:hover {
    background: rgba(110, 72, 170, 0.05);
    transform: translateY(-3px);
}

.btn-disabled {
    background: #ddd;
    color: #999;
    cursor: not-allowed;
}

.image-placeholder {
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 20px;
    position: absolute;
    top: 0;
    left: 0;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: var(--shadow);
    opacity: 0;
    transition: opacity 0.5s;
    position: relative;
}

/* 项目区域 */
.projects {
    padding: 100px 0;
}

.section-title {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 60px;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--gradient);
    border-radius: 2px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.project-card {
    background: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.project-image {
    height: 200px;
    position: relative;
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.5s;
}

.project-content {
    padding: 25px;
}

.project-content h3 {
    font-size: 22px;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.project-description {
    color: var(--light-text);
    margin-bottom: 15px;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.project-tags span {
    background: rgba(110, 72, 170, 0.1);
    color: var(--primary-color);
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 12px;
}

/* 关于我区域 */
.about {
    display: flex;
    align-items: center;
    gap: 60px;
    padding: 100px 0;
}

.about-image {
    flex: 1;
    height: 500px;
    position: relative;
}

.about-content {
    flex: 1;
}

.about-content p {
    margin-bottom: 20px;
    color: var(--light-text);
}

.skills {
    margin-top: 30px;
}

.skill-item {
    margin-bottom: 15px;
}

.skill-name {
    margin-bottom: 8px;
    font-weight: 500;
}

.skill-bar {
    height: 8px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
    overflow: hidden;
}

.skill-progress {
    height: 100%;
    background: var(--gradient);
    border-radius: 4px;
    animation: progress 1.5s ease-in-out forwards;
}

@keyframes progress {
    from { width: 0; }
}

/* 页脚 */
.footer {
    background: var(--card-bg);
    padding: 60px 0 20px;
    margin-top: 60px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    display: flex;
    align-items: center;
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-color);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links a {
    color: var(--light-text);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-social {
    display: flex;
    gap: 20px;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(110, 72, 170, 0.1);
    color: var(--primary-color);
    border-radius: 50%;
    transition: all 0.3s;
}

.footer-social a:hover {
    background: var(--gradient);
    color: white;
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    color: var(--lighter-text);
    font-size: 14px;
}

/* 打字效果 */
.typing {
    position: relative;
}

.typing::after {
    content: '|';
    position: absolute;
    right: -8px;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* 响应式设计 */
@media (max-width: 992px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding: 60px 0;
    }
    
    .hero-content {
        padding-right: 0;
        margin-bottom: 40px;
    }
    
    .hero-subtitle {
        max-width: 100%;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .about {
        flex-direction: column;
    }
    
    .about-image {
        margin-bottom: 40px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
        transform: translateY(-150%);
        transition: transform 0.3s;
        z-index: 99;
    }
    
    .nav-links.active {
        transform: translateY(0);
    }
    
    .nav-links li {
        margin: 15px 0;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .hero-title {
        font-size: 36px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 30px;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 15px;
    }
    
    .btn {
        width: 100%;
    }
    
    .section-title {
        font-size: 28px;
    }
}
    </style>
</head>
<body>
    <!-- 加载动画 -->
    <div class="loader">
        <div class="hamster-wheel">
            <div class="hamster"></div>
        </div>
    </div>

    <!-- 背景元素 -->
    <div class="bg-grid"></div>
    <div class="bg-circles">
        <div class="circle circle-1"></div>
        <div class="circle circle-2"></div>
        <div class="circle circle-3"></div>
    </div>

    <!-- 主容器 -->
    <div class="container">
        <!-- 导航栏 -->
        <nav class="navbar">
            <div class="logo">
                <span class="logo-icon">🐹</span>
                <span class="logo-text">仓鼠の官网</span>
            </div>
            <ul class="nav-links">
                <li><a href="#home" class="active">首页</a></li>
                <li><a href="https://yzycoc.com/qq">部落仓鼠工具</a></li>
                <li><a href="https://yzycoc.com/blog">仓鼠博客</a></li>
                <li><a href="#projects">我的项目</a></li>
                <li><a href="#about">关于我</a></li>
            </ul>
            <div class="mobile-menu-btn">
                <i class="fas fa-bars"></i>
            </div>
        </nav>

        <!-- 主要内容 -->
        <main>
            <!-- 英雄区域 -->
            <section id="home" class="hero">
                <div class="hero-content">
                    <h1 class="hero-title">
                        <span class="title-line">你好，我是<span class="highlight">仓鼠</span></span>
                        <span class="title-line">一枚热爱<span class="typing"></span>的程序猿</span>
                    </h1>
                    <p class="hero-subtitle">这是我的个人官网，记录了我的学习历程和技术作品</p>
                    <div class="hero-buttons">
                        <a href="#projects" class="btn btn-primary">查看项目</a>
                        <a href="https://yzycoc.com/blog" class="btn btn-secondary">阅读博客</a>
                    </div>
                </div>
                <div class="hero-image">
                    <div class="image-placeholder"></div>
                    <img src="https://example.com/hamster-coding.jpg" alt="仓鼠编程" loading="lazy" onload="this.style.opacity=1">
                </div>
            </section>

            <!-- 项目展示 -->
            <section id="projects" class="projects">
                <h2 class="section-title">我的<span class="highlight">项目</span></h2>
                <div class="projects-grid">
                    <!-- 项目1 -->
                    <div class="project-card">
                        <div class="project-image">
                            <div class="image-placeholder"></div>
                            <img src="https://example.com/project1.jpg" alt="部落仓鼠工具" loading="lazy" onload="this.style.opacity=1">
                        </div>
                        <div class="project-content">
                            <h3>部落仓鼠工具</h3>
                            <p class="project-description">QQ微信群部落冲突机器人，提供部落冲突阵型库等功能</p>
                            <div class="project-tags">
                                <span>机器人</span>
                                <span>游戏工具</span>
                                <span>微信QQ</span>
                            </div>
                            <a href="https://yzycoc.com/qq" class="btn btn-primary">访问项目</a>
                        </div>
                    </div>
                    
                    <!-- 项目2 -->
                    <div class="project-card">
                        <div class="project-image">
                            <div class="image-placeholder"></div>
                            <img src="https://example.com/project2.jpg" alt="仓鼠的博客" loading="lazy" onload="this.style.opacity=1">
                        </div>
                        <div class="project-content">
                            <h3>仓鼠的博客</h3>
                            <p class="project-description">分享技术文章、学习笔记和生活感悟</p>
                            <div class="project-tags">
                                <span>技术博客</span>
                                <span>学习笔记</span>
                                <span>个人分享</span>
                            </div>
                            <a href="https://yzycoc.com/blog" class="btn btn-primary">访问博客</a>
                        </div>
                    </div>
                    
                    <!-- 项目3 -->
                    <div class="project-card">
                        <div class="project-image">
                            <div class="image-placeholder"></div>
                            <img src="https://example.com/project3.jpg" alt="仓鼠API服务" loading="lazy" onload="this.style.opacity=1">
                        </div>
                        <div class="project-content">
                            <h3>仓鼠API服务</h3>
                            <p class="project-description">提供各种实用的API接口服务</p>
                            <div class="project-tags">
                                <span>API</span>
                                <span>Web服务</span>
                                <span>开发中</span>
                            </div>
                            <a href="#" class="btn btn-disabled" onclick="alert('该服务暂未开放分享，敬请期待！')">即将开放</a>
                        </div>
                    </div>
                </div>
            </section>

            <!-- 关于我 -->
            <section id="about" class="about">
                <div class="about-image">
                    <div class="image-placeholder"></div>
                    <img src="https://example.com/about-me.jpg" alt="关于仓鼠" loading="lazy" onload="this.style.opacity=1">
                </div>
                <div class="about-content">
                    <h2 class="section-title">关于<span class="highlight">我</span></h2>
                    <p>我是一名热爱编程的程序员，专注于Web开发和自动化工具开发。</p>
                    <p>通过这个网站，我希望能记录自己的学习历程，分享开发经验，并与志同道合的朋友交流。</p>
                    <p>目前主要的技术栈包括：JavaScript, Python, Node.js, Vue.js等。</p>
                    <div class="skills">
                        <div class="skill-item">
                            <div class="skill-name">Web开发</div>
                            <div class="skill-bar">
                                <div class="skill-progress" style="width: 85%"></div>
                            </div>
                        </div>
                        <div class="skill-item">
                            <div class="skill-name">自动化工具</div>
                            <div class="skill-bar">
                                <div class="skill-progress" style="width: 78%"></div>
                            </div>
                        </div>
                        <div class="skill-item">
                            <div class="skill-name">API开发</div>
                            <div class="skill-bar">
                                <div class="skill-progress" style="width: 75%"></div>
                            </div>
                        </div>
                    </div>
                </div>
            </section>
        </main>

        <!-- 页脚 -->
        <footer class="footer">
            <div class="footer-content">
                <div class="footer-logo">
                    <span class="logo-icon">🐹</span>
                    <span class="logo-text">仓鼠の官网</span>
                </div>
                <div class="footer-links">
                    <a href="#home">首页</a>
                    <a href="https://yzycoc.com/qq">部落仓鼠工具</a>
                    <a href="https://yzycoc.com/blog">仓鼠博客</a>
                    <a href="#projects">我的项目</a>
                    <a href="#about">关于我</a>
                </div>
                <div class="footer-social">
                    <a href="#"><i class="fab fa-github"></i></a>
                    <a href="#"><i class="fab fa-twitter"></i></a>
                    <a href="#"><i class="fab fa-weixin"></i></a>
                    <a href="#"><i class="fas fa-envelope"></i></a>
                </div>
            </div>
            <div class="footer-bottom">
                <p>&copy; 2023 仓鼠の官网. 保留所有权利.</p>
            </div>
        </footer>
    </div>

    <script>
        // JavaScript 代码将在下方详细展示
        // 加载完成后隐藏加载动画
window.addEventListener('load', function() {
    setTimeout(function() {
        document.querySelector('.loader').classList.add('hidden');
    }, 1000);
});

// 移动端菜单切换
document.querySelector('.mobile-menu-btn').addEventListener('click', function() {
    document.querySelector('.nav-links').classList.toggle('active');
});

// 平滑滚动
document.querySelectorAll('a[href^="#"]').forEach(anchor => {
    anchor.addEventListener('click', function(e) {
        e.preventDefault();
        
        const targetId = this.getAttribute('href');
        if (targetId === '#') return;
        
        const targetElement = document.querySelector(targetId);
        if (targetElement) {
            window.scrollTo({
                top: targetElement.offsetTop - 80,
                behavior: 'smooth'
            });
            
            // 关闭移动菜单
            document.querySelector('.nav-links').classList.remove('active');
        }
    });
});

// 打字效果
const typingTexts = ['编程', '学习', '创造', '分享'];
const typingElement = document.querySelector('.typing');
let textIndex = 0;
let charIndex = 0;
let isDeleting = false;
let typingSpeed = 100;

function type() {
    const currentText = typingTexts[textIndex];
    
    if (isDeleting) {
        typingElement.textContent = currentText.substring(0, charIndex - 1);
        charIndex--;
        typingSpeed = 50;
    } else {
        typingElement.textContent = currentText.substring(0, charIndex + 1);
        charIndex++;
        typingSpeed = 100;
    }
    
    if (!isDeleting && charIndex === currentText.length) {
        isDeleting = true;
        typingSpeed = 1500; // 暂停一下
    } else if (isDeleting && charIndex === 0) {
        isDeleting = false;
        textIndex = (textIndex + 1) % typingTexts.length;
        typingSpeed = 500; // 切换单词前的暂停
    }
    
    setTimeout(type, typingSpeed);
}

// 开始打字效果
setTimeout(type, 1000);

// 滚动时导航栏效果
window.addEventListener('scroll', function() {
    const navbar = document.querySelector('.navbar');
    if (window.scrollY > 50) {
        navbar.style.background = 'rgba(255, 255, 255, 0.95)';
        navbar.style.boxShadow = '0 5px 20px rgba(0, 0, 0, 0.1)';
        navbar.style.padding = '15px 0';
    } else {
        navbar.style.background = 'transparent';
        navbar.style.boxShadow = 'none';
        navbar.style.padding = '20px 0';
    }
});

// 懒加载图片观察器
if ('IntersectionObserver' in window) {
    const lazyImageObserver = new IntersectionObserver(function(entries, observer) {
        entries.forEach(function(entry) {
            if (entry.isIntersecting) {
                const lazyImage = entry.target;
                lazyImage.src = lazyImage.dataset.src;
                lazyImageObserver.unobserve(lazyImage);
            }
        });
    });
    
    document.querySelectorAll('img[loading="lazy"]').forEach(function(lazyImage) {
        lazyImageObserver.observe(lazyImage);
    });
}
    </script>
</body>
</html>